Most modern, dynamic web pages make numerous asynchronous JavaScript and extensible markup language (XML) (AJAX) calls from a client to retrieve content from a server. An AJAX call is hypertext transport protocol (HTTP) request initiated by client side code (typically JavaScript) that returns data to be rendered into the page. For example, a page describing a product for sale might initially display generic content about the product, which can be heavily cached and delivered to the user very quickly. Shortly thereafter, the page may be asynchronously updated with personalized content that is specific to the user, such as the user's viewing history (e.g., “you're looking at product B, but you last looked at product A”.) The personalized content is delivered via an AJAX call to give the user a fast and efficient experience.
A complex dynamic web page may include many personalizations or other customizations. In addition, modern web applications are so large that they may be worked on by very large software teams, such that the personalizations and customizations may be implemented by numerous developers. Because it is uncommon for such large teams to be able to communicate perfectly, this can result in numerous AJAX calls that may occur in parallel or may be serialized. The multiplicity of AJAX calls can adversely affect performance. In particular, serialization of AJAX calls on networks with high latency can create very poor perceived performance because each request cannot be sent (and thus a response cannot be received) until the previous request completes.
The standard solution to this problem is to reconfigure page logic to combine requests. For instance, suppose developer Ann writes code that requests personalization data X, and developer Burt writes code that requests personalization data Y. Performance could be improved by rewriting the code written by Ann and Burt. In a typical instance, the server would be updated to include an endpoint that will return information X and Y. The code written by Ann and Burt would be rewritten to perform a single AJAX request that uses the new endpoint. The new code would extract data X from the response and invoke Ann's code, and extract data Y from the response and invoke Burt's code. This works, but involves a substantial rewrite of code at significant expense and also entails an unrealistic level of coordination between developers and teams.